Namespace Producto
Public Class Marca
	Inherits Auditoria.Transaccion

	Private vMarcaId As Integer = -1
	Private vNombre As String = ""
	Private vDescripcion As String = ""
	Private vCatalogo As Integer = -1

	Public Property MarcaId() As Integer
		Get
			Return vMarcaId
		End Get
		Set(ByVal Value As Integer)
			vMarcaId = Value
		End Set
	End Property

	Public Property Nombre() As String
		Get
			Return vNombre
		End Get
		Set(ByVal Value As String)
			vNombre = Value
		End Set
	End Property

	Public Property Descripcion() As String
		Get
			Return vDescripcion
		End Get
		Set(ByVal Value As String)
			vDescripcion = Value
		End Set
	End Property

	Public Property Catalogo() As Integer
		Get
			Return vCatalogo
		End Get
		Set(ByVal Value As Integer)
			vCatalogo = Value
		End Set
	End Property

	Sub New()
	End Sub

	Sub New(ByRef MarcaId As Integer, ByVal Nombre As String, ByVal Descripcion As String, ByVal Catalogo As Integer)
		vMarcaId = MarcaId
		vNombre = Nombre
		vDescripcion = Descripcion
		vCatalogo = Catalogo
	End Sub

End Class



 Public Class MarcaCol   
 Inherits System.Collections.CollectionBase
Private _enmSortDirection As SortDirection
Public Sub New()
_enmSortDirection = SortDirection.Asc
End Sub
Public Sub Sort(ByVal sortExpression As String, ByVal sortDirection As SortDirection)
InnerList.Sort(New Comparer(sortExpression, SortDirection))
End Sub
Public Sub Sort(ByVal sortExpression As String)
InnerList.Sort(New Comparer(sortExpression, _enmSortDirection))
If _enmSortDirection = SortDirection.Asc Then
_enmSortDirection = SortDirection.Desc
Else
_enmSortDirection = SortDirection.Asc
End If
End Sub
Public Function Add(ByVal obj As Marca) As Integer
Return MyBase.List.Add(obj)
End Function
Public Sub AddPrimero(ByVal obj As Marca)
MyBase.List.Insert(0, obj)
End Sub
Public ReadOnly Property Marca(ByVal Index As Integer) As Marca
Get
Return CType(MyBase.List(Index), Marca)
End Get
End Property
End Class
end namespace

